#include <stdio.h>  
int main(int argc, char **argv) {  
    int x;  
    int max = 0, min = 2147483647, ans = 0;  
  
    for (int i = 0; i < 10; i++) {  
        if (scanf("%d", &x));  
        ans += x;  
        max = max > x ? max : x;  
        min = min < x ? min : x;  
    }  
    ans -= min + max;  
    ans /= 8;  
    printf("Canceled Max Score:%d\nCanceled Min Score:%d\nAverage Score:%d\n", max, min, ans);  
    return 0;  
}  